Integrand size = 32, antiderivative size = 147 \[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\frac {6 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 b^3 d \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}}+\frac {2 C \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {b \sec (c+d x)}}{3 b^4 d}+\frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {2 C \sin (c+d x)}{3 b^3 d \sqrt {b \sec (c+d x)}} \]
[Out]
Time = 0.14 (sec) , antiderivative size = 147, normalized size of antiderivative = 1.00, number of steps used = 9, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.219, Rules used = {4132, 3854, 3856, 2719, 12, 16, 2720} \[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\frac {2 C \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {b \sec (c+d x)}}{3 b^4 d}+\frac {6 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 b^3 d \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}}+\frac {2 C \sin (c+d x)}{3 b^3 d \sqrt {b \sec (c+d x)}}+\frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}} \]
[In]
[Out]
Rule 12
Rule 16
Rule 2719
Rule 2720
Rule 3854
Rule 3856
Rule 4132
Rubi steps \begin{align*} \text {integral}& = \frac {B \int \frac {1}{(b \sec (c+d x))^{5/2}} \, dx}{b}+\int \frac {C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx \\ & = \frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {(3 B) \int \frac {1}{\sqrt {b \sec (c+d x)}} \, dx}{5 b^3}+C \int \frac {\sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx \\ & = \frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {C \int \frac {1}{(b \sec (c+d x))^{3/2}} \, dx}{b^2}+\frac {(3 B) \int \sqrt {\cos (c+d x)} \, dx}{5 b^3 \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}} \\ & = \frac {6 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 b^3 d \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}}+\frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {2 C \sin (c+d x)}{3 b^3 d \sqrt {b \sec (c+d x)}}+\frac {C \int \sqrt {b \sec (c+d x)} \, dx}{3 b^4} \\ & = \frac {6 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 b^3 d \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}}+\frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {2 C \sin (c+d x)}{3 b^3 d \sqrt {b \sec (c+d x)}}+\frac {\left (C \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}\right ) \int \frac {1}{\sqrt {\cos (c+d x)}} \, dx}{3 b^4} \\ & = \frac {6 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{5 b^3 d \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)}}+\frac {2 C \sqrt {\cos (c+d x)} \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right ) \sqrt {b \sec (c+d x)}}{3 b^4 d}+\frac {2 B \sin (c+d x)}{5 b^2 d (b \sec (c+d x))^{3/2}}+\frac {2 C \sin (c+d x)}{3 b^3 d \sqrt {b \sec (c+d x)}} \\ \end{align*}
Time = 1.24 (sec) , antiderivative size = 91, normalized size of antiderivative = 0.62 \[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\frac {2 \sqrt {\cos (c+d x)} \sqrt {b \sec (c+d x)} \left (9 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )+5 C \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )+\sqrt {\cos (c+d x)} (5 C+3 B \cos (c+d x)) \sin (c+d x)\right )}{15 b^4 d} \]
[In]
[Out]
Result contains complex when optimal does not.
Time = 2.81 (sec) , antiderivative size = 566, normalized size of antiderivative = 3.85
method | result | size |
parts | \(\frac {2 B \left (3 i \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \cos \left (d x +c \right )-3 i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \cos \left (d x +c \right )+6 i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )-6 i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )+3 i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )-3 i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )+\cos \left (d x +c \right )^{2} \sin \left (d x +c \right )+\sin \left (d x +c \right ) \cos \left (d x +c \right )+3 \sin \left (d x +c \right )\right )}{5 d \left (\cos \left (d x +c \right )+1\right ) \sqrt {b \sec \left (d x +c \right )}\, b^{3}}-\frac {2 C \left (i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )+i \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )-\sin \left (d x +c \right )\right )}{3 d \sqrt {b \sec \left (d x +c \right )}\, b^{3}}\) | \(566\) |
default | \(\frac {-\frac {6 i B \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \cos \left (d x +c \right )}{5}+\frac {6 i B \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \cos \left (d x +c \right )}{5}-\frac {2 i C \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \cos \left (d x +c \right )}{3}-\frac {12 i B \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )}{5}+\frac {12 i B \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )}{5}-\frac {4 i C \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right )}{3}+\frac {2 B \sin \left (d x +c \right ) \cos \left (d x +c \right )^{2}}{5}-\frac {6 i B \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )}{5}+\frac {6 i B \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticE}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )}{5}-\frac {2 i C \sqrt {\frac {1}{\cos \left (d x +c \right )+1}}\, \sqrt {\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {EllipticF}\left (i \left (-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ), i\right ) \sec \left (d x +c \right )}{3}+\frac {2 B \cos \left (d x +c \right ) \sin \left (d x +c \right )}{5}+\frac {2 C \cos \left (d x +c \right ) \sin \left (d x +c \right )}{3}+\frac {6 B \sin \left (d x +c \right )}{5}+\frac {2 C \sin \left (d x +c \right )}{3}}{d \left (\cos \left (d x +c \right )+1\right ) \sqrt {b \sec \left (d x +c \right )}\, b^{3}}\) | \(635\) |
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 0.10 (sec) , antiderivative size = 164, normalized size of antiderivative = 1.12 \[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\frac {-5 i \, \sqrt {2} C \sqrt {b} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right ) + 5 i \, \sqrt {2} C \sqrt {b} {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right ) + 9 i \, \sqrt {2} B \sqrt {b} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right )\right ) - 9 i \, \sqrt {2} B \sqrt {b} {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right )\right ) + 2 \, {\left (3 \, B \cos \left (d x + c\right )^{2} + 5 \, C \cos \left (d x + c\right )\right )} \sqrt {\frac {b}{\cos \left (d x + c\right )}} \sin \left (d x + c\right )}{15 \, b^{4} d} \]
[In]
[Out]
\[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\int \frac {\left (B + C \sec {\left (c + d x \right )}\right ) \sec {\left (c + d x \right )}}{\left (b \sec {\left (c + d x \right )}\right )^{\frac {7}{2}}}\, dx \]
[In]
[Out]
\[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\int { \frac {C \sec \left (d x + c\right )^{2} + B \sec \left (d x + c\right )}{\left (b \sec \left (d x + c\right )\right )^{\frac {7}{2}}} \,d x } \]
[In]
[Out]
\[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\int { \frac {C \sec \left (d x + c\right )^{2} + B \sec \left (d x + c\right )}{\left (b \sec \left (d x + c\right )\right )^{\frac {7}{2}}} \,d x } \]
[In]
[Out]
Timed out. \[ \int \frac {B \sec (c+d x)+C \sec ^2(c+d x)}{(b \sec (c+d x))^{7/2}} \, dx=\int \frac {\frac {B}{\cos \left (c+d\,x\right )}+\frac {C}{{\cos \left (c+d\,x\right )}^2}}{{\left (\frac {b}{\cos \left (c+d\,x\right )}\right )}^{7/2}} \,d x \]
[In]
[Out]